#ifndef _GRAPHICS_DEVICE_H
#define _GRAPHICS_DEVICE_H

namespace Graphics
{
	struct SetupInfo;

	class Device
	{
	public:
		Device();
		~Device();

		bool InitDevice(HINSTANCE aHInstance, const SetupInfo& aSetupInfo);
		void Destroy();
		
		LPDIRECT3DDEVICE9 GetDevice();
		HWND GetWindow();

	private:
		bool SetupWindow(const SetupInfo& aSetupInfo);
		bool InitD3DDevice(const SetupInfo& aSetupInfo);

	private:
		HINSTANCE myHInstance;
		HWND myWindow;

		LPDIRECT3D9 myD3D;
		LPDIRECT3DDEVICE9 myDevice;
	};
}

#endif